home *** CD-ROM | disk | FTP | other *** search
/ Compute! Gazette 1987 August / 1987-08.d64 / sprite flip demo (.txt) < prev    next >
Commodore BASIC  |  2022-09-20  |  2KB  |  48 lines

  1. 10 rem copyright 1987 - compute! publications, inc. all rights reserved
  2. 20 data 0,0,0,127,192,0,127,192
  3. 30 data 0,126,0,0,127,0,0,119
  4. 40 data 128,0,115,192,0,113,224,0
  5. 50 data 0,240,0,0,120,0,0,60
  6. 60 data 0,0,30,0,0,15,0,0
  7. 70 data 7,128,0,3,192,0,1,224
  8. 80 data 0,0,240,0,0,120,0,0
  9. 90 data 60,0,0,30,0,0,12,255
  10. 100 data 102,102,100,102,102,100,102,102
  11. 110 data 100,102,102,100,102,102,100,102
  12. 120 data 102,100,102,102,100,102,102,100
  13. 130 data 102,102,100,102,102,100,102,102
  14. 140 data 100,102,102,100,255,254,100,238
  15. 150 data 238,100,251,190,100,238,238,100
  16. 160 data 251,190,100,238,238,100,251,190
  17. 170 data 100,238,238,100,255,254,100,250
  18. 180 print"[147]":poke53280,0:poke53281,0
  19. 190 printchr$(142):ford=1to24:print"":next
  20. 200 printspc(5)"[213][196][201] copyright 1987"
  21. 210 printspc(5)"[199]c[200] compute! publications inc."
  22. 220 printspc(5)"[202][198][203] all rights reserved"
  23. 230 forx=1to15:print"[145]";:next
  24. 240 printspc(11)"[154]sprite flip demo[146]"
  25. 250 ford=1to2500:next
  26. 260 poke53280,0:poke53281,0:print"[147]"
  27. 270 printchr$(14)"[155]":v=53248:fors=832to958:readx:pokes,x:next
  28. 280 poke2040,14:poke2041,13
  29. 290 pokev+21,7
  30. 300 pokev+40,5
  31. 310 poke53277,3:poke53271,3
  32. 320 pokev,240:pokev+1,202
  33. 330 poke53276,1:poke53287,1:poke53286,6:poke53285,2
  34. 340 pokev+2,70:pokev+3,202
  35. 350 printchr$(14)"[147][155]"
  36. 360 print"[212]his machine language routine will"
  37. 370 print"maximize the potential of your sprite"
  38. 380 print"data. [201]t allows you to flip sprites"
  39. 390 print"vertically or horizontally. [212]herefore,"
  40. 400 print"you can produce four sprites from only"
  41. 410 print"one definition. [193]nimated sprites are"
  42. 420 print"possible without using valuable memory."
  43. 430 print"[208][210][197][211][211] ([200])orizontal [207][210] ([214])ertical [212][207] [198][204][201][208]"
  44. 440 geta$:ifa$=""then440
  45. 450 ifa$="h"thenpoke781,13:sys49152:poke781,14:sys49155:goto440
  46. 460 ifa$="v"thenpoke781,13:sys49158:poke781,14:sys49158:goto440
  47. 470 goto440
  48.